<?php
/*
 * 提醒事件状态自动检测接口
 */
class Apiv1_ChkstatusController extends Ctrl_Api{
    public function indexAction(){
        $p = $_REQUEST;
        $tTime = time();

        $tRPMO = new RemindplanModel;
        $tSql = 'update '.$tRPMO->table.' set status = 2 where status = 0 and respondtime >= '.($tTime-20*60).' and respondtime <= '.$tTime;
        if(!$tRPMO->update($tSql)){
            Tool_Fnc::ajaxMsg('操作失败');
        }
    }
}
?>

